import request from '@/utils/request'
import axios from 'axios'
import {
  transformQueryCondition
} from '@/utils'
import qs from 'qs'

const busiDemoPrefix = '/busidemo'

//获取主键ID
export function getUUID(){
    return request({
      url: busiDemoPrefix + '/util/getUuid',
      method: 'GET'
    })
  }

// 检索
export function Select(query) {
    const searchCon = transformQueryCondition(query)
    return request({
      url: busiDemoPrefix + '/TSgbankAddress/select',
      method: 'POST',
      data: searchCon
    })
  }

  // 插入
export function Insert(data) {
    //const search = qs.stringify(data)
    return request({
      url: busiDemoPrefix + '/TSgbankAddress',
      method: 'POST',
      data: data
    })
  }

  // 更新
export function Update(data) {
    return request({
      url: busiDemoPrefix + '/TSgbankAddress/'+ data.id,
      method: 'PUT',
      data: data
    })
  }

// 强制删除
export function DeleteItem(data) {
    return request({
      url: busiDemoPrefix + '/TSgbankAddress',
      method: 'DELETE',
      data: data
    })
  }